package com.lb.design.pattern.singletonpattern;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: liubin
 * Date: 2017-12-29
 * Time: 下午 3:23
 */
public class SinglePattern {

    private static  final SinglePattern singlePattern = new SinglePattern();


    /**
     *     限制住往往只能产生一个实例
     */

    private  SinglePattern(){}

    public synchronized static SinglePattern getInstance(){
        return  singlePattern;
    }

}
